]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
layoutManager: Return null monitor if focusIndex is invalid
authorMarco Trevisan (Treviño) <mail@3v1n0.net>
Thu, 28 Jun 2018 14:51:48 +0000 (16:51 +0200)
committerMarco Trevisan (Treviño) <mail@3v1n0.net>
Thu, 28 Jun 2018 15:05:30 +0000 (17:05 +0200)
https://bugzilla.gnome.org/show_bug.cgi?id=788882

js/ui/layout.js

index 6f810395da1153d4fa19be5e7f48b8c830219d76..dcffe479ced4ee17868ffe60c771fea41ab122a3 100644 (file)
@@ -557,6 +557,8 @@ var LayoutManager = new Lang.Class({
     },
 
     get focusMonitor() {
+        if (this.focusIndex < 0)
+            return null;
         return this.monitors[this.focusIndex];
     },